<!DOCTYPE html>
<html>
<head>
	<meta charset="UTF-8">
	<title><?=$this->lang->line('site_title');?></title>
	<meta http-equiv="X-UA-Compatible" content="IE=edge"/>	
	<meta http-equiv="cache-control" content="max-age=0" />
	<meta http-equiv="cache-control" content="no-cache" />
	<meta http-equiv="expires" content="0" />
	<meta http-equiv="expires" content="Tue, 01 Jan 1980 1:00:00 GMT" />
	<meta http-equiv="pragma" content="no-cache" />

	<link rel="stylesheet" href="<?=base_url()?>assets/css/jquery-ui-1.10.2.custom.min.css" />
	<link rel="stylesheet" href="<?=base_url()?>assets/css/style.css" />
	<link rel="stylesheet" href="<?=base_url()?>assets/css/text-buble.css" />
	<link rel="stylesheet" href="<?=base_url()?>assets/css/jquery.dtpicker.css" />

	<link rel="stylesheet" href="<?=base_url()?>assets/css/jquery.touchpanview.css" />
    <link rel="apple-touch-icon-precomposed" sizes="144x144" href="assets/ico/apple-touch-icon-144-precomposed.png">
    <link rel="apple-touch-icon-precomposed" sizes="114x114" href="assets/ico/apple-touch-icon-114-precomposed.png">
      <link rel="apple-touch-icon-precomposed" sizes="72x72" href="assets/ico/apple-touch-icon-72-precomposed.png">
                    <link rel="apple-touch-icon-precomposed" href="assets/ico/apple-touch-icon-57-precomposed.png">
                                   <link rel="shortcut icon" href="assets/ico/favicon.png">
	

	<script src="<?=base_url()?>assets/js/libs/json2.min.js"></script>
	<script src="<?=base_url()?>assets/js/libs/l10n.min.js"></script>
	<script src="<?=base_url()?>assets/js/libs/localizations.js"></script>
	<script type="text/javascript"> 
 var filename="<?=$file_name?>";
    function toggle_visibility(id) { 
       var e = document.getElementById(id);
       var a = document.getElementById('maximize');
       if(e.style.display == 'block'){
          e.style.display = 'none';
          a.style.display = 'block';
        
		  }
       else{
          e.style.display = 'block';
          a.style.display = 'none';
		  }
    }
	
	function max_visibility(id) {
       var e = document.getElementById(id);
	   var a = document.getElementById('maximize');
       if(a.style.display == 'block'){
          a.style.display = 'none';
          e.style.display = 'block';
		  }
       else{
          a.style.display = 'block';
          e.style.display = 'none';
		  }
    }

	function onnload(){ 
		if (/MSIE (\d+\.\d+);/.test(navigator.userAgent)){ // MSIE x.x; 
			var ieversion=new Number(RegExp.$1);
			if(ieversion<9){
				alert("<?=$this->lang->line('compatible_ie');?>"); 
				window.location.href = baseurl + "auth/logout"; 
			}
		}
	}
	 window.onload = onnload;
	</script>
	
</head>

<body oncontextmenu='return false;'>


<div id="window"></div>
<section class="contents">	
	<div id="overlay-event"></div>
	<div id="overlay" style="display:block">
		<img id="img-loading" src="<?=base_url()?>assets/css/images/ajax_loader.gif" alt="Loading" />
	</div>
	<div id="maximize"><a href="#" onclick="max_visibility('header');"><div class="button_maximize"></div></a></div>
	
	
	<table class="content" style="">
		<tr>
			<td class="history_column" id="page_thumbnails">
				<a class="minimize_history" onClick="App.minimize()" style="z-index:5554;"></a>
				
				<span id="layerstitle"><?=$this->lang->line('caption_history');?></span>
				<div class="player_control">
				<input type="button" value="<?=$this->lang->line('history_reset');?>" onClick="App.reset()">
				<input type="button" value="<?=$this->lang->line('history_auto_play');?>" onClick="App.autoPlay()">
				<input type="button" value="<?=$this->lang->line('history_stop');?>" onClick="App.stopAutoPlay()">
				<input type="button" value="<?=$this->lang->line('history_next');?>" onClick="App.next()">
				<input type="button" value="<?=$this->lang->line('history_prev');?>" onClick="App.prev()">
				<br>
				<br>
				<?=$this->lang->line('history_jump_to_date');?> <br><input type="text" id="date-picker">
				<input type="button" value="<?=$this->lang->line('history_go');?>" onClick="App.jumpToDate()">
				<br>
				<br>
				</div>
				<div class="historyContainer">
				<table border="1" style="border:1px black solid;">
				<tr >
					<td><?=$this->lang->line('history_num_label');?></td>
					<td><?=$this->lang->line('history_operation_label');?></td>
					<td><?=$this->lang->line('history_object_type_label');?></td>
					<td><?=$this->lang->line('history_user_label');?></td>
					<td><?=$this->lang->line('history_time_label');?></td>
				</tr>
				<?$index=0;?>
				<?foreach($file_history as $single_history){?>
					<tr id="history_<?=$index?>" class="history_cells" data-history="<?=$index?>" style="background-color:white;cursor:pointer;">
						<td><?=$index+1?></td>
						<td><?=$single_history->operation?></td>
						<!--Nanda - Notes: Change attribute type to attribute object_type
						<td><?=$single_history->type?></td>-->
						<td><?=$single_history->object_type?></td>
						<td><?=$single_history->user->username?></td>
						<!-- Nanda Notes - All Device and Browser : Set time to time zone japan -->
						<?date_default_timezone_set('JAPAN');?>
						<td><?=date("Y/m/d H:i",$single_history->updated_time)?><input type="hidden" id="h_id_<?=$single_history->history_id?>" value="<?=$single_history->updated_time?>" /> 
					</tr>
					<?$index++;?>
				<?}?>
				<tr>
				</tr>
				</table>
			 
				</div>
			</td>
			<td class="drawContainer" id="draw_column" style="min-height:600px;overflow:scroll;">
				<a class="maximize_parent" id="maximize_button" onClick="App.maximize()" style="z-index:5554;display:none;left:0px;"></a>
				<div id="rootContainer">
				
					
				</div>
				
			</td>
		</tr>
		<tr>
			<td>
				<div id="chat_div"></div>
			</td>
		</tr>
	</table>
</section>
<input id="base_url" type="hidden" value="<?=base_url();?>"/>
<input id="file_id" type="hidden" value="<?=$file_id;?>"/>
<input id="page_id" type="hidden" value="<?=$page_id;?>"/>
<input id="app_lang" type="hidden" value="<?=$this->config->item('language');?>"/>
<script type="text/javascript" src="<?=base_url()?>assets/js/libs/require.js" data-main="<?=base_url()?>assets/js/main-player"></script>


</body>
</html>
